<!DOCTYPE html>
<html xmlns:th="http://www.thymeleaf.org">
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
    <th:block th:include="common.html :: source"></th:block>
    <script type="text/javascript" src="/js/productDetail.js"></script>
</head>
<body>

<th:block th:include="common.html :: header"></th:block>
<th:block th:include="common.html :: category"></th:block>

<div class="i_bg">
    <div class="postion">
    </div>
    <div class="content" style="margin-left: 390px">
        <div id="tsShopContainer" style="float:left;">
            <div id="tsImgS">
                <a th:href="'/images/'+${product.fileName}" title="Images" class="MagicZoom" id="MagicZoom">
                    <img th:src="'/images/'+${product.fileName}" width="390" height="390"
                         style="border:1px solid #EAEAEA;"/>
                </a>
            </div>
        </div>
        <div class="pro_des">
            <div class="des_name">
                <input type="hidden" value="1" name="entityId" class="n_ipt"/>
                <p>[[${product.name}]]</p>
            </div>
            <div class="des_price">
                所需积分：<b>[[${product.integral}]]</b><br/>
            </div>
            <div class="des_price">
                库存：<b id="stock" th:text="${product.stock}"></b><br/>
            </div>
            <br>
            <br>
            <div class="des_join">
                <div class="j_nums">
                    <input type="text" id="quantity" value="1" name="quantity" class="n_ipt"/>
                    <input type="button" value="" onclick="increase()" class="n_btn_1"/>
                    <input type="button" value="" onclick="reduce()" class="n_btn_2"/>
                </div>
                <input type="hidden" id="productId" th:value="${product.id}">
                <input type="hidden" id="totalIntegrals" th:value="${totalIntegrals}">
                <input type="hidden" id="integrals" th:value="${product.integral}">
                <span class="fl">
                     <img src="/images/j_duihuan.png" onclick="addOrders()"/>
                </span>
            </div>
        </div>
    </div>
</div>

<th:block th:include="common.html :: footer"></th:block>
<th:block th:include="common.html :: permit"></th:block>

</body>
</html>